@echo off
set version=%1
if "%version%"=="" set version=1
set REPOSITORY=registry.cn-hangzhou.aliyuncs.com/weilus923/admin-k8s
set TAG=1.0.%version%

echo docker build -t %REPOSITORY%:%TAG% .
docker build -t %REPOSITORY%:%TAG% .

echo docker push %REPOSITORY%:%TAG%
docker push %REPOSITORY%:%TAG%

echo docker rmi %REPOSITORY%:%TAG%
docker rmi %REPOSITORY%:%TAG%

echo kubectl apply -f k8s.yaml
kubectl apply -f k8s.yaml